home *** CD-ROM | disk | FTP | other *** search
/ Ahoy 1986 April / Ahoy_Magazine_86-04_1986_Double_L.d64 / rooting routine (.txt) < prev    next >
Commodore BASIC  |  2022-10-26  |  221b  |  13 lines

  1. 1 rem
  2. 2 rem problem #23-2 :
  3. 3 rem  rooting routine
  4. 4 rem solution by
  5. 5 rem  stephan fassbender
  6. 6 rem
  7. 10 input "integer ";x
  8. 20 ug=int(x/256)
  9. 30 for n=ug to x
  10. 40 if n*(n+1)<x then next n
  11. 50 print x,"integer square root = ";n
  12. 60 goto 10
  13.